import java.util.Scanner;

public class Test20230811_3 {
    public static void main(String[] args){
        int [] num= {1,2,3,4,5,,6,7,8,9};
        Scanner scanner= new Scanner(System.in);
        int target = scanner.nextInt();
        for(int i=0; i<num.length; i++){
            for(int j=1; j<num.length-i; j++){
                if(num[i]+num[j]==target){
                    System.out.println(i+","+j);
                    break;
                }
            }
        }
    }
}
